package com.atguigu.test1;

/**
 * @author 路飞
 * @date 2024/3/28 10:21
 * @description
 */
public class Exer30 {
    public static void main(String[] args) throws InterruptedException {
        MyThread m = new MyThread();
        Thread t = new Thread(m);
        t.start();

//        t.join();


        int j = m.i;
        System.out.println(j);
    }

}

class MyThread implements Runnable{
    int i;
    public void run(){
        try {
            Thread.sleep(1000);
        } catch (Exception e) {
            e.printStackTrace();
        }
        i=100;
    }
}

